import request from '@/utils/request'

// 查询挂号流水表列表
export function listRegistration(query) {
  return request({
    url: '/outpatient/registration/list',
    method: 'get',
    params: query
  })
}

//接诊改挂号表状态
export function changeListState(data) {
  return request({
    url: '/outpatient/registration/changeListState',
    method: 'post',
    data: data
  })
}

// 新增病历单
export function addPatient(data) {
  return request({
    url: '/user/patient/addPatient',
    method: 'post',
    data: data
  })
}
// zc查询挂号流水表列表
export function listRegistrations(query) {
  return request({
    url: '/outpatient/registration/PendingDiagnosis',
    method: 'get',
    params: query
  })
}





// 查询挂号流水表详细
export function getRegistration(registrationId) {
  return request({
    url: '/outpatient/registration/' + registrationId,
    method: 'get'
  })
}

// 查询科室ID名称详细
export function getdeptList() {
  return request({
    url: '/outpatient/registration/getdeptList',
    method: 'get'
  })
}

// 查询医师详细
export function getDoctorList() {
  return request({
    url: '/outpatient/registration/getDoctorList',
    method: 'get'
  })
}


// 查询医师详细
export function getDoctorLikeList() {
  return request({
    url: '/user/doctor/getDoctorLikeLists',
    method: 'get'
  })
}



// 新增挂号流水表
export function addRegistration(data) {
  return request({
    url: '/outpatient/registration/addRegistration',
    method: 'post',
    data: data
  })
}

// 修改挂号流水表
export function updateRegistration(data) {
  return request({
    url: '/outpatient/registration',
    method: 'put',
    data: data
  })
}

// 删除挂号流水表
export function delRegistration(registrationId) {
  return request({
    url: '/outpatient/registration/' + registrationId,
    method: 'delete'
  })
}
